---
layout: main
---
<article class="article-page">
  <div class="page-content">
    {% if page.img %}
    <div class="page-cover-image">
      <figure>
        <img class="page-image" src={{ "/assets/img/" | prepend: site.baseurl | append : page.img}} alt="{{page.title}}">
        {% if page.fig-caption %}
          <figcaption>{{page.fig-caption}}</figcaption>
        {% endif %}
      </figure>
    </div> <!-- End Page Cover Image -->
    {% else %}
    {% endif %}
    <div class="wrap-content">
      <header class="header-page">
        <h1 class="page-title">{{page.title}}</h1>
        <div class="page-date"><span>{{page.date | date: '%Y, %b %d'}}&nbsp;&nbsp;&nbsp;&nbsp;</span></div>
      </header>
      {{content | markdownify}}
      <div class="page-footer">
        <div class="page-share">
          <a href="https://twitter.com/intent/tweet?text={{ page.title }}&url={{ site.url }}{{ page.url }}" title="Share on Twitter" rel="nofollow" target="_blank">Twitter</a>
          <a href="https://facebook.com/sharer.php?u={{ site.url }}{{ page.url }}" title="Share on Facebook" rel="nofollow" target="_blank">Facebook</a>
          <a href="https://plus.google.com/share?url={{ site.url }}{{ page.url }}" title="Share on Google+" rel="nofollow" target="_blank">Google+</a>
        </div>
        <div class="page-tag">
          {% for tag in page.tags %}
            <a href="{{site.baseurl}}/tags#{{tag}}" class="tag">&#35; {{ tag }}</a>
          {% endfor %}
        </div>
      </div>
    </div>
    <div id="container"></div>
    <link rel="stylesheet" href="https://imsun.github.io/gitment/style/default.css">
    <script src="https://imsun.github.io/gitment/dist/gitment.browser.js"></script>
    <script>
      var title_length ='{{ page.title }}'.length;
      var title = ""
      if (title_length < 50 && '{{ page.title }}'.indexOf(",")== -1){
        title = "{{ page.title }}";
      }else{
        title = "{{ page.date }}"
      }
      var gitment = new Gitment({
        id: title,
        owner: 'CainGao0',
        repo: 'caingao0.github.io',
        oauth: {
          client_id: '57c14b686b63ce17ed05',
          client_secret: '698bb22fdfd6a6b16139589235d4555f0ac02f56',
        },
      })
      gitment.render('container')
    </script><!-- End Wrap Content -->
  </div> <!-- End Page Content -->
</article> <!-- End Article Page -->
